<template>
  <div class="fns-header-cascader">
	<!-- ========可以快捷地搜索选项并选择======-->
	<el-cascader
			:placeholder=" isSHow ? '请选择或搜索地址' : ''"
			v-model="cascaderData.area"
			:options="cascaderData.cascader"
			filterable
			:props="propData"
			:clearable="cascaderData.isValidate ? true : false"
			:disabled="cascaderData.isValidate ? false : true"
			@change="handleChange"
			@blur="blur"
			change-on-select>
	</el-cascader>
  </div>
</template>

<script>
  export default {
	props: {
	  cascaderData: {
		cascader: {
		  default: []
		},
		isValidate: {
		  default: false
		},
		area: {
		  default: []
		}
	  }
	},
	computed: {
	},
	watch: {
	},
	created () {
	},
	data() {
	  return {
	  isSHow: true,
		cascaderVal: [],
		propData: {
		  label: 'name',
		  value: 'code'
		}
	  }
	},
	methods: {
		changeVal() {
			this.isSHow = false
		},
	  handleChange(val) {
		this.$emit('cascaderChange', val)
	  },
	  blur(val) {
		this.$emit('cascaderBlur')
	  }
	}
  }
</script>

<style lang="scss">
  /*级联*/
  /*.is-disabled input{*/
	/*cursor: not-allowed!important;*/
  /*}*/
  .fns-header-cascader {
	.el-cascader {
	  width: 100%;
	}
  }
</style>
